package com.itheima.project1.Mapper;

import com.itheima.project1.Pojo.User;
import org.apache.ibatis.annotations.*;

import java.util.List;

@Mapper
public interface userMapper {
    @Select("select * from user where id=#{id}")
    List<User> userList(Integer id);
    @Insert("insert into user(id,name,gender,birthday) values (#{id},#{name},#{gender},#{birthday})")
    void userInsert(User user);
    @Delete("delete from user where id=#{id} ")
    void userDelete(Integer id);
    @Update("update user set name=#{user.name},gender=#{user.gender},birthday=#{user.birthday} where id=#{id}")
    void userUpdate(Integer id,User user);
}
